#!/usr/bin/env python
# encoding: utf-8
'''
@author: 王震
@license: 四川凡狼科技有限公司
@contact: 2668985108@qq.com
@file: note.py
@time: 2021/10/2 11:17 上午
@desc:
'''

from main import db
import datetime


class Note(db.Model):
    __tablename__ = 'NOTE'

    id = db.Column(db.String(32), primary_key=True, unique=True, nullable=False, comment='id')
    details = db.Column(db.Text, unique=False, nullable=True, comment='笔记详情')
    parentId = db.Column(db.String(32), unique=False, nullable=False, comment='id')
    createTime = db.Column(db.DateTime, unique=False, nullable=True, default=datetime.datetime.now, comment='创建时间')
    updateTime = db.Column(db.DateTime, unique=False, nullable=True, default=datetime.datetime.now,
                           onupdate=datetime.datetime.now, comment='更新时间')
